package com.zds.y_entity;

import lombok.Data;

/**
 * @className:ResultEntity
 * @date: 2025/1/16 下午12:13
 * @description:
 */
@Data
public class ResultEntity {
    public final static int CODE_OK = 200;
    public final static int CODE_ERROR = 500;
    public final static int CODE_NOT_FOUND = 404;
    private Object data;
    private String msg;
    private int code = CODE_OK;
    public ResultEntity() {
    }
    public ResultEntity(String msg,Object data) {
        this.data = data;
        this.msg = msg;
    }

    public ResultEntity(String msg,int code){
        this.code=code;
        this.msg=msg;
    }
    public ResultEntity(int code,String msg,Object data){
        this.code=code;
        this.msg=msg;
        this.data=data;
    }
    public ResultEntity(int code){
        this.code=code;
    }
    public ResultEntity(String msg){
        this.code=code;
    }
}
